tests: Avoid rounding error and correct source pixels
authorMartin Nordholts <martinn@src.gnome.org>
Fri, 18 May 2012 11:31:38 +0000 (13:31 +0200)
committerMartin Nordholts <martinn@src.gnome.org>
Fri, 18 May 2012 11:31:38 +0000 (13:31 +0200)
commitdb935097ce132d3fed3e8bf9e6e6ef69b9976986
tree36c0a8c47590c7126d13396aa3bfc2594753dbce
parent8167d33480d05308b753ad61acaaa17ff2f26c3c
tests: Avoid rounding error and correct source pixels

In float-to-8bit.c and "float -> u8 6", change 0.3 to 0.301 since 0.3
/ 0.6 * 255 = 127.5, so the slightest platform specific rounding error
will give different results for u8 (127 or 128).

Also correct G'a and B'a values in the third pixel to match expected
values, the source values seems to have forgotten about
premultiplication.
tests/float-to-8bit.c